﻿#include <stdio.h>
int main()
{
	int m = 0;
	int n = 0;
	scanf("%d %d", &m, &n);
	int k = (m > n ? m : n);
	while (1)
	{
		if (k % m == 0 && k % n == 0)
		{
			printf("%d\n", k);
			break;
		}
		k++;
	}
	return 0;
}

//⽅法2

#include <stdio.h>
int main()
{
	int m = 0;
	int n = 0;
	scanf("%d %d", &m, &n);//18 24
	int k = 0;
	int mul = m * n;
	while (k = m % n)
	{
		m = n;
		n = k;
	}
	printf("%d\n", mul / n);
	return 0;
}